package com.heima.utils.thread;

import com.heima.model.wemedia.pojos.WmUser;

/**
 * @author jack
 * @data 2024 14:28
 */

public class WmThreadLocalUtil {
    public static ThreadLocal<WmUser> threadLocal = new ThreadLocal<>();

    public static void setUser(WmUser wmUser){
        threadLocal.set(wmUser);
    }

    public static WmUser getUser(){
        return threadLocal.get();
    }

    public static void remove(){
        threadLocal.remove();
    }
}
